package com.ruoyi.quartz.service.impl;

import com.ruoyi.quartz.domain.DrugsNotice;
import com.ruoyi.quartz.mapper.DrugsNoticeMapper;
import com.ruoyi.quartz.service.IDrugsNoticeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 库存预警Service业务层处理
 * 
 * @author wyj
 * @date 2025-04-25
 */
@Service
public class DrugsNoticeServiceImpl implements IDrugsNoticeService 
{
    @Autowired
    private DrugsNoticeMapper drugsNoticeMapper;

    /**
     * 查询库存预警
     * 
     * @param id 库存预警主键
     * @return 库存预警
     */
    @Override
    public DrugsNotice selectDrugsNoticeById(Long id)
    {
        return drugsNoticeMapper.selectDrugsNoticeById(id);
    }

    /**
     * 查询库存预警列表
     * 
     * @param drugsNotice 库存预警
     * @return 库存预警
     */
    @Override
    public List<DrugsNotice> selectDrugsNoticeList(DrugsNotice drugsNotice)
    {
        return drugsNoticeMapper.selectDrugsNoticeList(drugsNotice);
    }

    /**
     * 新增库存预警
     * 
     * @param drugsNotice 库存预警
     * @return 结果
     */
    @Override
    public int insertDrugsNotice(DrugsNotice drugsNotice)
    {
        return drugsNoticeMapper.insertDrugsNotice(drugsNotice);
    }

    /**
     * 修改库存预警
     * 
     * @param drugsNotice 库存预警
     * @return 结果
     */
    @Override
    public int updateDrugsNotice(DrugsNotice drugsNotice)
    {
        return drugsNoticeMapper.updateDrugsNotice(drugsNotice);
    }

    /**
     * 批量删除库存预警
     * 
     * @param ids 需要删除的库存预警主键
     * @return 结果
     */
    @Override
    public int deleteDrugsNoticeByIds(Long[] ids)
    {
        return drugsNoticeMapper.deleteDrugsNoticeByIds(ids);
    }

    /**
     * 删除库存预警信息
     * 
     * @param id 库存预警主键
     * @return 结果
     */
    @Override
    public int deleteDrugsNoticeById(Long id)
    {
        return drugsNoticeMapper.deleteDrugsNoticeById(id);
    }
}
